﻿#pragma warning(disable: 4477)
#pragma warning(disable: 4996)
#pragma warning(disable: 6031)
#pragma warning(disable: 6054)
/*

 */
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <math.h>

typedef struct TContext_s
{
	int n;
	char a[10001];
	char b[10001];
}TContext;

TContext context;
 
void read_data(TContext* ctx)
{
	gets(ctx->a);
	gets(ctx->b);
}

void do_task(TContext* ctx)
{
	char* pa = ctx->a;
	char* pb = ctx->b;
	while (*pa)
	{
		char* pc = pb;
		while (*pc)
		{
			if (*pc == *pa)
				break;
			++pc;
		}
		if (*pc == 0)
			printf("%c", *pa);
		++pa;
	}
	printf("\n");
}

void solve(TContext* ctx)
{
	read_data(ctx);
	do_task(ctx);
}

int main()
{
	freopen("D:/Develop/GitRepos/MOOC/浙江大学/数据结构/201906/DataStructure/M2019秋C入门和进阶练习集/7-122.txt", "r", stdin);
	solve(&context);
	return 0;
}
